package r21118d1119nw;

public class ObjectEquals {

    public static void main(String[] args) {
        int x = 10;
        int y = 20;
        char z = 'a';
        int m = 97;
        System.out.println(x==y);
        System.out.println(z==m);

        Stu stu1 = new Stu("zhangsan","11");
        Stu stu2 = new Stu("zhangsan","11");
        Stu stu3 = stu1;
        System.out.println(stu1==stu2);
        System.out.println(stu1);
        System.out.println(stu2);
        System.out.println(stu1==stu3);

        System.out.println(stu1.equals(stu2));
        System.out.println(stu1.equals(stu3));
    }
}


